The history of Baghdad begins when city of Baghdad ( Baġdād) was founded in the mid 8th century as the Abbasid capital, following the Abbasid victory over the Omayyad Caliphate. It replaced the Sassanid capital of Seleucia-Ctesiphon some 35 km to the south-east, which was mostly depopulated by the end of the 8th century. Baghdad was the center of the Arab caliphate during the "Golden Age of Islam" of the 9th and 10th centuries, growing to be the largest city worldwide by the beginning of the 10th century. It began to decline in the "Iranian Intermezzo" of the 9th to 11th centuries, and was destroyed in the Mongolian invasion in 1258.